# Contributor: Grigory Kirillov <txgk@bk.ru>
# Maintainer: Celeste <cielesti@protonmail.com>
pkgname=md4c
pkgver=0.4.8
pkgrel=2
pkgdesc="Fast Markdown parser written in C"
url="https://github.com/mity/md4c"
arch="all"
license="MIT"
options="!check" # no test suite
makedepends="cmake samurai"
source="https://github.com/mity/md4c/archive/release-$pkgver/md4c-$pkgver.tar.gz"
subpackages="$pkgname-libs $pkgname-dev $pkgname-doc"
builddir="$srcdir/md4c-release-$pkgver"

build() {
	cmake -B builddir -G Ninja \
		-DCMAKE_BUILD_TYPE=Release \
		-DCMAKE_INSTALL_PREFIX=/usr
	cmake --build builddir
}

package() {
	DESTDIR="$pkgdir" cmake --install builddir
}

sha512sums="
c939fdadf3e05c32c570cf9a5c0a02f83afaf4dfacf0f4505fcf12c6e24ffe0cd1372c207ff47cf2a489b02f24c5f20bb5f1361453c847c5464225cc7fcdb5ab  md4c-0.4.8.tar.gz
"
